Skip to content

feat(storage): hash pins on S3/GCS via object metadata - #951

Closed
devitway wants to merge 1 commit into
mainfrom
reland/947-object-store-pins
Closed

feat(storage): hash pins on S3/GCS via object metadata#951
devitway wants to merge 1 commit into
mainfrom
reland/947-object-store-pins

Conversation

@devitway

@devitway devitway commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Relands #947 (by @jgrund), rebased onto current main.

Records the SHA-256 integrity pin as object metadata (x-amz-meta-sha256 / x-goog-meta-sha256) on the S3 and GCS backends. The pin is written atomically with the object (on put_opts / the multipart init), so an object is never stored without its pin; get re-verifies the pin on read and fails closed on a mismatch. Raw uploads are additionally validated against an RFC 9530 Repr-Digest header when present.

Also adds a direct validate_storage_key() at the top of Storage::get() for defense in depth.

Closes #947

Reland of #947 (jgrund), rebased onto main: resolves the CHANGELOG conflict;
gc.rs auto-merges cleanly with #950. Also adds a direct validate_storage_key() at
the top of Storage::get() (defense-in-depth, mirrors get_verified) so the
trust-boundary invariant is not left to transitive get_pinned() validation.

Gate green: fmt/clippy/test (63+1781/0), OPSEC clean, trust-boundary 13/13 SAFE,
polygon A/B (pin rides as x-amz-meta-sha256, bad Repr-Digest -> 400).

Closes #947
@devitway
devitway requested a review from ertime037 as a code owner September 3, 2026 18:44
@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown

🐳 Test image pushed: ghcr.io/getnora-io/nora:pr-951

docker pull ghcr.io/getnora-io/nora:pr-951
docker run --rm -p 4000:4000 ghcr.io/getnora-io/nora:pr-951

@ertime037
ertime037 enabled auto-merge September 4, 2026 07:15
@devitway devitway added the reland Maintainer: reland an approved PR as a signed web-flow commit (auto-reland.yml) label Sep 4, 2026
@devitway

devitway commented Sep 4, 2026

Copy link
Copy Markdown
Contributor Author

Superseded by #952 — same reviewed diff re-landed as one web-flow-signed commit (main requires verified signatures; these commits were unsigned). Closing.

Note: the auto-reland workflow failed with Bad credentials (401) — the RELAND_TOKEN secret is expired and needs renewing for the automated path.

@devitway devitway removed the reland Maintainer: reland an approved PR as a signed web-flow commit (auto-reland.yml) label Sep 4, 2026
@devitway devitway closed this Sep 4, 2026
auto-merge was automatically disabled September 4, 2026 07:23

Pull request was closed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants